package com.tz.tzgw.pc.web.config;

import com.tz.tzgw.pc.web.dao.*;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.jdbc.core.JdbcTemplate;

@Configuration
public class AppConfig {

    private final JdbcTemplate jdbcTemplate;

    public AppConfig(JdbcTemplate jdbcTemplate) {
        this.jdbcTemplate = jdbcTemplate;
    }

    @Bean
    public MemberDao memberDao() {
        return new MemberDao(jdbcTemplate);
    }

    @Bean
    public MemberRoleDao memberRoleDao() {
        return new MemberRoleDao(jdbcTemplate);
    }

    @Bean
    public RoleDao roleDao() {
        return new RoleDao(jdbcTemplate);
    }

    @Bean
    public RoleMenuDao roleMenuDao() {
        return new RoleMenuDao(jdbcTemplate);
    }

    @Bean
    public MenuDao MenuDao() {
        return new MenuDao(jdbcTemplate);
    }
    @Bean
    public SiteDao SiteDao() {
        return new SiteDao(jdbcTemplate);
    }

    @Bean
    public CompanyDao CompanyDao() {
        return new CompanyDao(jdbcTemplate);
    }

    @Bean
    public WebcolumnDao WebcolumnDao() {
        return new WebcolumnDao(jdbcTemplate);
    }

    @Bean
    public BannerDao BannerDao() {
        return new BannerDao(jdbcTemplate);
    }
    @Bean
    public ArticleDao ArticleDao() {
        return new ArticleDao(jdbcTemplate);
    }

    @Bean
    public ZtArticleDao ZtArticleDao() {
        return new ZtArticleDao(jdbcTemplate);
    }

    @Bean
    public ZtVideoDao ZtVideoDao() {
        return new ZtVideoDao(jdbcTemplate);
    }


    @Bean
    public ZtImagesDao ZtImagesDao() {
        return new ZtImagesDao(jdbcTemplate);
    }

    @Bean
    public ZtVideoCateDao ZtVideoCateDao() {
        return new ZtVideoCateDao(jdbcTemplate);
    }

    @Bean
    public ZtSetDao ZtSetDao() {
        return new ZtSetDao(jdbcTemplate);
    }

    @Bean
    public ZhaopinDao ZhaopinDao() {
        return new ZhaopinDao(jdbcTemplate);
    }

    // 其他配置...
}
